<template>
  <div class="login">
    <div class="login-logo">
      <img src="@/assets/image/logo.png" alt />
    </div>
    <div class="login-title">军事科学院研究生院（互联网）后台管理系统</div>
    <div class="login-banner">
      <div class="banner-left">
        <img src="@/assets/image/login-left.png" alt />
      </div>
      <div class="banner-right">
        <div class="right-tit">后台管理登录</div>
        <div class="login-input">
          <el-input v-model="loginForm.account" placeholder="请输入内容"></el-input>
        </div>
        <div class="login-input">
          <el-input placeholder="请输入密码" v-model="loginForm.password" show-password></el-input>
        </div>
        <div class="remember">
          <el-checkbox v-model="checked">记住密码</el-checkbox>
        </div>
        <div class="login-button">
          <el-button type="primary" @click="Login">登录</el-button>
        </div>
      </div>
    </div>
  </div>
</template>

<script >
import * as api from '@/utils/api'
export default {
  name: "login",
  components: {},
  data () {
    return {
      checked: true,
      loginForm: {
        account: 'admin',
        password: '123456'
      }
    }
  },
  methods: {
    Login () {
      api.setToken('ZxXxCxVxBNxM')
      this.$router.push('/workBench/frontPage')
      this.$message({
        message: '登录成功',
        type: 'success'
      });
    }
  }
}
</script>

<style lang="scss" scoped>
.login {
  overflow: hidden;
  background: url(~@/assets/image/login-ground.png) no-repeat center;
  background-size: 100% 100%;
  min-height: 100vh;
  .login-logo {
    width: 125px;
    height: 125px;
    margin: 50px auto 20px;
    img {
      width: 100%;
      height: 100%;
    }
  }
  .login-title {
    width: 480px;
    height: 30px;
    font-weight: 700;
    color: #ffffff;
    font-size: 24px;
    margin: 0 auto 40px;
  }
  .login-banner {
    overflow: hidden;
    display: flex;
    // opacity: 90%;
    width: 1580px;
    height: 535px;
    border-radius: 48px;
    margin: 0 auto;
    background: url(~@/assets/image/login-banner.png);
    background-size: 100% 100%;
    .banner-left {
      padding: 20px;
      width: 960px;
      img {
        width: 100%;
        height: 100%;
      }
    }
    .remember {
      margin-top: 10px;
    }
    .banner-right {
      padding: 100px;
      width: 620px;
      background: #adb1cc;
      .right-tit {
        color: #333333;
        font-size: 18px;
        font-weight: 700;
      }
      .login-button {
        margin-top: 70px;
        .el-button {
          width: 420px;
          height: 60px;
          background-color: #be1015;
        }
        border-radius: 5px;
      }
      .login-input {
        margin-top: 20px;
        .el-input {
          height: 60px;
          >>> .el-input__inner {
            border: 1px solid #121010;
            font-size: 20px;
            height: 60px;
          }
        }
      }
    }
  }
}
</style>
